unit Unit_test;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Soap.InvokeRegistry, Vcl.StdCtrls,
  Soap.Rio, Soap.SOAPHTTPClient;

type
  TForm1 = class(TForm)
    HTTPRIO1: THTTPRIO;
    Button1: TButton;
    Button2: TButton;
    Button3: TButton;
    Button4: TButton;
    Memo1: TMemo;
    Memo2: TMemo;
    Label1: TLabel;
    Label2: TLabel;
    procedure Button1Click(Sender: TObject);
    procedure Button2Click(Sender: TObject);
    procedure Button3Click(Sender: TObject);
    procedure Button4Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;
  ret : OleVariant;

implementation

{$R *.dfm}

uses Iselfservice1;

procedure TForm1.Button1Click(Sender: TObject);
var
  testobj : ISelfService;
begin
  testobj := HTTPRIO1 as ISelfService;
  ret := testobj.GetPatChargeType(Memo1.Text);
  Memo2.Lines.Add(ret);
end;

procedure TForm1.Button2Click(Sender: TObject);
var
  testobj : ISelfService;
begin
  HTTPRIO1.HTTPWebNode.SendTimeout := 100000;
  HTTPRIO1.HTTPWebNode.ConnectTimeout := 100000;
  HTTPRIO1.HTTPWebNode.ReceiveTimeout := 100000;
  testobj := HTTPRIO1 as ISelfService;
  ret := testobj.GdaGetOutPay(Memo1.Text);
  Memo2.Lines.Add(ret);
end;

procedure TForm1.Button3Click(Sender: TObject);
var
  testobj : ISelfService;
begin
  testobj := HTTPRIO1 as ISelfService;
  ret := testobj.GdaInsertOutPay(Memo1.Text);
  Memo2.Lines.Add(ret);
end;

procedure TForm1.Button4Click(Sender: TObject);
var
  testobj : ISelfService;
begin
  testobj := HTTPRIO1 as ISelfService;
  ret := testobj.GetPatSIState(Memo1.Text);
  Memo2.Lines.Add(ret);
end;

end.
